package com.ironone.mediaplayerdemo;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.view.ViewPager;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.Button;

public class Frag2 extends Fragment {

	ViewPager viewPager;
	
	@Override
	public View onCreateView(LayoutInflater inflater, final ViewGroup container, Bundle savedInstanceState) {
		// Inflate the layout for this fragment
		View view = inflater.inflate(R.layout.frag_two, container, false);
		viewPager = (ViewPager) getActivity().findViewById(R.id.pager);
		
		Button dragIcon = (Button) view.findViewById(R.id.dragicon);
		dragIcon.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View arg0) {
				//viewPager.setCurrentItem(0, true);	
			}
		});
		
		return view;				
		//return view;
	}	
}
